package server.business.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import server.business.pojo.Nationality;
import server.business.service.NationalityService;

import java.util.List;

@Controller
@RequestMapping("/nationality")
public class NationalityController {
    @Autowired
    private NationalityService nationalityService;


    /**
     * 获取民族数据字典
     *
     * @return
     */
    @GetMapping("/normal/query")
    @ResponseBody
    public List<Nationality> getNationalityInfo() {
        return nationalityService.list();
    }
}
